<script language="javascript" type="text/javascript">

var dlat_treeinfo = $.parseJSON('<?cs var:config.treeinfo ?>');

function dlatSetTypeTree(treeinfo)
{
	var list = "<li><a href='#' onclick=\"$.bringBack({";
	list += "dam_attr_type:'" + treeinfo.type + "', dam_attr_type_name:'" + treeinfo.name + "'})\">";
	list += treeinfo.name + "</a>";

	if(treeinfo.subcount == 0) {
		list += "</li>";
		return list;
	}

	list += "<ul>";
	var listsub = treeinfo.list;
	for(var i=0; i < treeinfo.subcount && i < listsub.length; i++)
		list += dlatSetTypeTree(listsub[i]);
	list += "</ul>";

	list += "</li>";
	return list;
}

$(document).ready(function(){
	var thtml = dlatSetTypeTree(dlat_treeinfo);
	var obj= $("#dlat_attr_type_list");
	obj.html(thtml);
});

</script>

<div class="pageContent">
	<div class="pageFormContent" layoutH="58">
		<ul class="tree treeFolder" id="dlat_attr_type_list">
		</ul>
	</div>
	
	<div class="formBar">
		<ul>
			<li><button type="button" class="buttonActive close">关闭</button></li>
		</ul>
	</div>
</div>

